package com.xueyi.system.productionManager.service.impl;

import com.xueyi.system.productionManager.domain.po.BaseProductionManagerPo;
import com.xueyi.system.productionManager.domain.query.BaseProductionManagerQuery;
import com.xueyi.system.productionManager.domain.dto.BaseProductionManagerDto;
import com.xueyi.system.productionManager.service.IBaseProductionManagerService;
import com.xueyi.system.productionManager.manager.IBaseProductionManagerManager;
import com.xueyi.common.web.entity.service.impl.BaseServiceImpl;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * 生产管理管理 服务层处理
 *
 * @author zlf
 */
@Service
public class BaseProductionManagerServiceImpl extends BaseServiceImpl<BaseProductionManagerQuery, BaseProductionManagerDto, IBaseProductionManagerManager> implements IBaseProductionManagerService {

    @Autowired
    private IBaseProductionManagerManager baseProductionManagerManager;

    /**
     * 查询生产管理对象列表 | 数据权限 | 附加数据
     *
     * @param productionManager 生产管理对象
     * @return 生产管理对象集合
     */
    @Override
    //@DataScope(userAlias = "createBy", mapperScope = {"BaseProductionManagerMapper"})
    public List<BaseProductionManagerDto> selectListScope(BaseProductionManagerQuery productionManager) {
        return baseManager.selectListExtra(productionManager);
    }

    @Override
    public List<BaseProductionManagerDto> findByList(String plantId) {
        return baseProductionManagerManager.findByList(plantId);
    }

    @Override
    public List<BaseProductionManagerDto> findMothByList(String month) {
        return baseProductionManagerManager.findMothByList(month);
    }
}
